using System;

namespace Thinxoft.HttpLib
{
	/// <summary>
	/// Represents a response to the client application
	/// </summary>
	public interface IHttpResponse
	{
        void Clear();

		/// <summary>
		/// writes a string to the response buffer
		/// </summary>
		/// <param name="text"></param>
		void Write(string text);

		/// <summary>
		/// write with params
		/// </summary>
		/// <param name="text"></param>
		/// <param name="args"></param>
		void Write(string text, params string[] args);

		/// <summary>
		/// redirects to a new location
		/// </summary>
		/// <param name="format"></param>
		/// <param name="args"></param>
		void Redirect(string format, params string[] args);		
		/// <summary>
		/// adds http headers to the response
		/// </summary>
		/// <param name="name"></param>
		/// <param name="val"></param>
		void AddHeader(string name, string val);

		/// <summary>
		/// removes http headers from the response
		/// </summary>
		/// <param name="name"></param>
		void RemoveHeader(string name);

		/// <summary>
		/// represents the collection of cookies to be sent back to  the  client application
		/// </summary>
		IHttpCookies ResponseCookies
		{
			get
				;
			
		}

		/// <summary>
		/// retruns the length of the response
		/// </summary>
		int Length
		{
			get
				;
		}
		
	}
}
